﻿<UserControl x:Class="HM.UI.UserControls.ReportsTab"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d" 
             d:DesignHeight="300" d:DesignWidth="300">
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto" />
            <RowDefinition Height="Auto" />
            <RowDefinition Height="Auto" />
            <RowDefinition Height="Auto" />
            <RowDefinition Height="Auto" />
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="Auto" />
            <ColumnDefinition Width="Auto" />
            <ColumnDefinition Width="Auto" />
            <ColumnDefinition Width="Auto" />
            <ColumnDefinition Width="*" />
        </Grid.ColumnDefinitions>

        <!--Labels-->
        <TextBlock Grid.Column="0" Grid.Row="0" Text="Get all payments" VerticalAlignment="Center" Margin="20 0" />
        <TextBlock Grid.Column="0" Grid.Row="1" Text="Get all expenses" VerticalAlignment="Center" Margin="20 0" />
        <TextBlock Grid.Column="0" Grid.Row="2" Text="Get payments from" VerticalAlignment="Center" Margin="20 0" />
        <TextBlock Grid.Column="2" Grid.Row="2" Text="to" VerticalAlignment="Center" Margin="20 0" />
        <TextBlock Grid.Column="0" Grid.Row="3" Text="Get expenses from" VerticalAlignment="Center" Margin="20 0" />
        <TextBlock Grid.Column="2" Grid.Row="3" Text="to" VerticalAlignment="Center" Margin="20 0" />
        <TextBlock Grid.Column="0" Grid.Row="4" Text="Get payments of " VerticalAlignment="Center" Margin="20 0" />

        <!--Buttons-->
        <Button Grid.Column="4" Grid.Row="0" Command="{Binding OpenAllPaymentsReportWindow}" Content="Go" Width="60" Margin="20 0" HorizontalAlignment="Right" />
        <Button Grid.Column="4" Grid.Row="1" Command="{Binding OpenAllExpensesReportWindow}" Content="Go" Width="60" Margin="20 0" HorizontalAlignment="Right" />
        <Button Grid.Column="4" Grid.Row="2" Command="{Binding OpenPaymentsByDateRangeReportWindow}" Content="Go" Width="60" Margin="20 0" HorizontalAlignment="Right" />
        <Button Grid.Column="4" Grid.Row="3" Command="{Binding OpenExpensesByDateRangeReportWindow}" Content="Go" Width="60" Margin="20 0" HorizontalAlignment="Right" />
        <Button Grid.Column="4" Grid.Row="4" Command="{Binding OpenPaymentsByTenantIdReportWindow}" Content="Go" Width="60" Margin="20 0" HorizontalAlignment="Right" />

        <!--Date Pickers-->
        <DatePicker Grid.Column="1" Grid.Row="2" SelectedDate="{Binding SelectedFromDateForPaymentsReport}" />
        <DatePicker Grid.Column="3" Grid.Row="2" SelectedDate="{Binding SelectedToDateForPaymentsReport}" />
        <DatePicker Grid.Column="1" Grid.Row="3" SelectedDate="{Binding SelectedFromDateForExpensesReport}" />
        <DatePicker Grid.Column="3" Grid.Row="3" SelectedDate="{Binding SelectedToDateForExpensesReport}" />

        <!--Combo-->
        <ComboBox
                    Grid.Column="1"
                    Grid.ColumnSpan="2"
                    Grid.Row="4"
                    ItemsSource="{Binding Tenants}"
                    DisplayMemberPath="Name"
                    SelectedItem="{Binding SelectedTenantForReport}" />

    </Grid>
</UserControl>
